import {setServer} from "@/utils/axios";
import {deviceUrl} from "../../../../url";

const request = setServer(deviceUrl);


// 查询设备管理单位人员
export function getEmployee(query) {
  return request({
    url: '/device/manager/employee/list',
    method: 'get',
    params:query
  })
}

// 查询设备管理单位人员详情
export function getEmployeeDetail(id) {
  return request({
    url: '/device/manager/employee/'+id,
    method: 'get',
  })
}

// 新增设备管理单位人员
export function addEmployee(query) {
  return request({
    url: '/device/manager/employee/',
    method: 'post',
    data:query
  })
}

// 修改设备管理单位人员
export function updateEmployee(query) {
  return request({
    url: '/device/manager/employee/',
    method: 'put',
    data:query
  })
}

// 删除设备管理单位人员
export function deleteEmployee(id) {
  return request({
    url: '/device/manager/employee/'+id,
    method: 'delete',
  })
}

// 管理单位人员写入门禁
export function managerWriteDoor(query) {
  return request({
    url: '/device/manager/employee/door',
    method: 'post',
    params:query
  })
}

